This invention is directed towards data storage systems, and more particularly towards physical backup and restore of databases serving multi-processor computers.
Computer systems allow the processing of massive quantities of data for a variety of purposes. As the ability to process data has increased, so has the need for data storage systems which provide massive data storage capabilities combined with fast access for host systems. Another feature required by many businesses and industries is continuous availability. Many businesses operate on a world-wide basis, and have a need for round-the-clock access to databases stored in one or more data storage systems. The data stored in these data storage systems is changing at an incredible rate, for example with transaction processing, reservation systems and data mining, the data is changing and updating many times per second.
Another requirement for data storage systems is periodic backup of data both for archival purposes and for data recovery in case of a system failure. For many businesses, a loss of data can be catastrophic. Therefore, system backups must be performed on a frequent basis.
However, the need for system backups often interferes with the need for continuous availability. With many data storage systems, performing a system backup requires taking the data storage system offline, thereby denying continuous access to the data.
One solution to this problem is used for RAID (Redundant Array of Independent Disks) systems. In RAID-1 systems, two physical storage devices, such as disks, each store identical data, in a process known as xe2x80x9cmirroringxe2x80x9d. This provides a very high level of fault tolerance in the form of redundancy, and it also allows data backups to be performed while still allowing continuous data access. Typically, the mirroring process is stopped (referred to as splitting the mirrors), and one of the disks is taken off-line and backed up, while the other disk remains online and available. When the first disk is completely backed up, the two disks are resynchronized (so that the data is identical on both), and the data storage system returns to full operation.
An overview of major components of a backup data system 10 is shown in FIG. 1. One or more host computer systems 12 access, process and store data from a data storage system 14. The host systems 12, including Massively Parallel Processor (MPP) or Symmetric Multi-Processor (SMP) systems are interfaced to the data storage system 14 over an interface 16, which may be any of various types of interface such as a network or SCSI interface. The host systems 12 are also interfaced 20 to a backup system 22, which provides data backup and restore to appropriate storage devices 24, for example via tape storage. This interface 20 between the host systems 12 and the backup system 22 is also any of various types of interface, such as a TCP/IP connection.
The data storage system 14 is any of various types of mass data storage systems, including for example a RAID system with multiple disks. A RAID-1 system is illustrated with two mirrored disk volumes (mirrors) 18a, 18b. The mirrors 18a, 18b are connected 21 such that the data is replicated on both mirrors 18a, 18b. Although the mirrors 18a, 18b are illustrated in a same data storage system 14 enclosure, the mirrors can be physically remote from each other, but still support RAID-1 mirroring using a remote data facility option, including a high-speed connection 21 such as an ESCON(copyright) fibre link connection.
For backup and restore of data stored on the data storage system 14, a standard method for backup requires the host systems 12 to extract the data from the databases on the data storage system 14 and pipe the data over to the backup management system 22. This method is incredibly slow, and it requires tying up the host system""s 12 time in the form of database access operations and data pipelining. A better solution is known as xe2x80x9cdirect connectxe2x80x9d. A high speed direct connection 26 is provided between the data storage system 14 and the backup management system 22, thereby allowing fast transfer of data directly to the backup management system 22, without the need for host system 12 intervention. This high speed direct connection 26 can be over any of various types of interfaces, such as a SCSI connection.
An example data storage system 14 is the Symmetrix mass storage system provided by EMC Corporation of Hopkinton, Mass. An example backup management system 22 is the EMC Data Manager (EDM). EDM can support backup and restore via three different methods, each tailored to particular backup environments and needs. The same EDM can support three different backup methods simultaneously, and enables host systems 12 and users to stay operational, with continued access to the data storage system 14 while backup occurs.
There are several types of database servers available, including parallel server databases. A parallel server database is a database server with enhancements that allow a common database to be shared among the nodes of an MPP or loosely coupled SMP system. A node can be an independent processor on an MPP or SMP machine, or a separate machine belonging to a clustered hardware environment. Parallel server databases provide processor scalability, where additional processing power may be added through the addition of more processor nodes, as well as high availability (also known as fault tolerance) in that if one processor node goes down, the other processor nodes can transparently take over the work of the down processor node.
However, there are problems related to parallel server databases. Since several nodes are accessing and writing the same database, there are problems relating to the coherency of the data. Further, backup and restore of the parallel server database becomes very complicated. Current systems are designed to handle backup and restore of a database which exists on a single database client machine, and which has only one node instance (thread) 30FIG. 2 associated with it. A thread is one process of multiple processes running on a computer system. A thread of change log information keeps track of the database changes made by a single instance.
Typical parallel server database applications, such as an Oracle(copyright) database from Oracle Corporation of Redwood Shores, Calif., have an architecture which includes several data files to maintain database coherence and availability. Such data files include a control file 32, which is a small administrative file required by every database, necessary to start and run a database system. A control file 32 is paired with a database, not with an instance 30. Multiple identical control files (not shown) are preferred to a single file 32, for reasons of data security. Other data files include a xe2x80x9credoxe2x80x9d log, which is a sequential log of actions that are to be reapplied to the database if they did not get written to disk. The log usually consists of at least two files; one is optionally being spooled to disk (archived) 34 while the other is being written (online) 36. Online redo logs 36 are redo logs that have not been archived. The online redo logs 36 may be available to the instance 30 for recording activity, or have previously been written but are awaiting archiving. Finally, there is typically a parameter file 38 which maintains instance-specific information, for example buffer sizes, archived redo log locations, and other routine information.
In this architecture (as shown in FIG. 2), the backup system is only concerned with backup and restore of (1) data files (not shown) as seen from the database client, (2) backup copy of the control file 32 as seen from the database client, and (3) archived redo logs 34 which reside in the archived log directory as seen from the database client. The online redo logs 36, and parameter or config files 38 are not backed up. Parallel server database providers recommend that online redo logs 36 should not be used in a backup/recovery scheme. Therefore, backup systems simply backup all archive log 34 and backup control file 32 information over the network 20 FIG. 1. These objects (archive redo logs 34 and control files 32) exist as files in a file system.
A parallel server database also places several restrictions on a backup system for a data storage system. All data files in a parallel server database configuration must reside on raw partitions (contiguous portions of a storage device such as a disk) and be visible to all parallel server database nodes. All online redo logs 36 and control files 32 must also reside in raw partitions and be visible to all parallel server database nodes. Also, one database is serviced by several instances 30, which means the backup system cannot simply equate the specific instance 30 with the database name. Finally, when doing a proper offline backup, the database must not be opened by any instance.
The present invention provides for safe and effective backup and restore of parallel server databases stored in data storage systems. Online or offline backup can be performed from any node in the system, with proper access to all control files and logs, both archived and online.
The present invention includes a backup system applicable to a parallel database in a clustered shared disk environment or MPP (massively parallel processor) environment where each instance has access to the exact same shared disk. This differs from other parallel database environments where the instances provide functionally different roles, and thus do not, necessarily, share a disk. These parallel databases are said to use xe2x80x9cfunction shippingxe2x80x9d.
In a parallel database environment where each node can see all of the database and control files, these files may be backed up from any of the nodes. Since there is a restriction that archived redo logs must be files in a file system, and there is a restriction at this time that file systems cannot be shared by multiple nodes of a cluster, each node""s instance must maintain its own local thread of archived redo logs. (There is also a restriction that archive logs be available for write processing locally). In order to ensure that all necessary files can be backed up from a single node, the archive logs from all nodes must be made accessible for read access by the chosen backup node. This access can be via NFS or other acceptable methods for the host operating system. All database data files, control files, and archived redo logs may then be backed up from a single node of the cluster.
At restore time, all restore and recovery actions may also take place on a single node. All of the database data files and control files may be restored to their original locations. All nodes will have the required access to these files as before. All of the archived redo logs, however, may be restored to the archived redo log directory of the restore node""s instance. Each log is named when created such that the database recovery command will recognize from which thread of redo it was created. This means that they do not need to be restored to their original location; only to a directory where they may be read by the recovering instance. In an illustrative embodiment of the present invention, however, it is desirable that the recovery node have NFS write ability to the other nodes. The archive logs are put back where they came from, to be more intuitive for the user. Users frequently must supply their own method for shutting down or starting up the database. This may be necessary for preparing applications for the database shutdown or startup. In order to facilitate this need, the user is supplied with xe2x80x9cexitsxe2x80x9d during the backup preparation and release phases to specify that a script be executed in place of the standard data base shutdown and startup.
The default action when no script is specified by the user is to shutdown the database in a way that ensures that all database data has been fully written to disk and that all instance processes on all nodes have been terminated. These commands can be issued from a single node (dbshut). The default action for startup of the database is to perform a normal startup for instances on all nodes. This can be issued from a single node.
Advantages of the present invention include online or offline backup and restore mechanisms for a parallel server database, such as Oracle Parallel Server (OPS), which is effective for redo archive logs as well as database information. This allows for single node discovery, preparation, and release of a multiple node database.
Other advantages of the present invention include a system where files can be backed up from any node. In a parallel database environment where each node can see all of the database and control files, these files may be backed up from any of the nodes.